<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%
	String path = request.getContextPath();
	String basePath = request.getScheme() + "://" + request.getServerName() + ":" + request.getServerPort()
			+ path + "/";
%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>订单详情页面</title>
<link rel="stylesheet" href="<%=basePath %>/res/wsz/js/layui/css/layui.css" media="all">
<script type="text/javascript" src="<%=basePath %>/res/wsz/js/base.js"></script>
<base href="<%=basePath %>">
</head>
<body>
<%--	<h3>订单详情</h3>--%>
	<table class="layui-hide" id="fodDetail" lay-filter="demo"></table>
 
<script type="text/html" id="barDemo">
</script>
 
<script src="<%=basePath %>/res/wsz/js/layui/layui.js"></script>
<script>

layui.use(['laydate', 'laypage', 'layer', 'table', 'upload', 'element'], function(){
	  var laydate = layui.laydate //日期
	  ,laypage = layui.laypage //分页
	  layer = layui.layer //弹层
	  ,table = layui.table //表格
	  ,upload = layui.upload //上传
	  ,element = layui.element; //元素操作
	 
	  
	  //监听Tab切换
	  element.on('tab(demo)', function(data){
	    layer.msg('切换了：'+ this.innerHTML);
	    console.log(data);
	  });
	  
	  //执行一个 table 实例
	  table.render({
	     elem: '#fodDetail'
	    ,height: 380
	    ,url: '<%=basePath %>fodDetail/findAll?indentId='+sessionStorage["indentId"] //数据接口
	    ,page: true //开启分页
	    ,method:'post'
	    ,cols: [[ //表头
	      {field: 'detail_id', title: '订单详情ID', width:120, fixed: 'left'}
	      ,{field: 'food_name', title: '食品名称', width:120}
	      ,{field: 'indent_name', title: '收货地址', width:120}
	      ,{field: 'food_price', title: '食物总价格', width:120}
	      ,{field: 'food_num', title: '食物总数量', width: 120}
	      ,{field: 'isva', title: '是否有效', width: 120}
	      ,{field: 'optime', title: '操作时间', width: 170}
	      ,{field: 'oper', title: '操作人', width: 100}
	    ]]
	  	,id: 'testReload'
	  });
});
</script>
</body>
</html>